<template>
  <div>
    <el-row>
      <el-col :span="24">
        提示信息
      </el-col>
    </el-row>
    <el-row>
      <el-col :span="12">
        <div class="tablewrap">
          <div v-for="(item, i) in tiShiInfo" :key="item.MESSAGE">({{ item.REMIND_ID }}) {{ item.MESSAGE }}</div>
        </div>
      </el-col>
      <el-col :span="12">
        <div class="tablewrap">
          <FilterTable :columns="columns" :isColumnFilter="false" :dataSource="dataSource" :height="200" :onColumnsChange="columns => (this.columns = columns)"></FilterTable>
        </div>
      </el-col>
    </el-row>
  </div>
</template>

<script>
import moment from 'moment';
import { retriveByControl } from '@/api/repair/business/customer/monitoring.js';

export default {
  name: 'TiShiXinXi',
  data() {
    return {
      // 提示信息
      tiShiInfo: [],
      // 提示信息 监控表格
      dataSource: [],
      columns: this.createColumnsMonitoring()
    };
  },
  mounted() {
    this.retriveByControl();
  },
  methods: {
    async retriveByControl() {
      const res = await retriveByControl();
      this.tiShiInfo = res;
      console.log(JSON.stringify(res, null, 2));
    },
    createColumnsMonitoring() {
      return [
        {
          title: '序号'
        },
        {
          title: '监控信息',
          dataIndex: ''
        }
      ];
    }
  }
};
</script>

<style scoped></style>
